<div class="row">
    <?php echo $form->labelEx($model->currentRevision, 'css_files'); ?>
</div>

<div class="files">
<?php if (is_array($model->currentRevision->css_files) && count($model->currentRevision->css_files)):?>
<?php foreach ($model->currentRevision->css_files as $index => $value):?>
<div class="row">
    <label>&nbsp;</label>
    <div class="actions">
    <?php $this->widget('Admin.components.FileWidget', array(
        'name'=>CHtml::resolveName($model->currentRevision, $attribute='css_files').'[]',
        'value'=>$value,
        'root'=>'/themes/'.Yii::app()->cmsManager->CmsTheme->name.'/styles/',
        'showButtonRemove'=>false,
    )); ?>
        <a href="#" onclick="return $.remove(this)" title="Remove" class="remove">Remove</a>
        <a href="#" onclick="return $.duplicate(this)" title="Add" class="add">Add</a>
    </div>
</div>
<?php endforeach;?>
<?php endif;?>
</div>

<div class="row">
    <?php echo $form->labelEx($model->currentRevision, 'js_files'); ?>
</div>

<div class="files">
<?php if (is_array($model->currentRevision->js_files) && count($model->currentRevision->js_files)):?>
<?php foreach ($model->currentRevision->js_files as $index => $value):?>
<div class="row">
    <label>&nbsp;</label>
    <div class="actions">
    <?php $this->widget('Admin.components.FileWidget', array(
        'name'=>CHtml::resolveName($model->currentRevision, $attribute='js_files').'[]',
        'value'=>$value,
        'root'=>'/themes/'.Yii::app()->cmsManager->CmsTheme->name.'/scripts/',
        'showButtonRemove'=>false,
    )); ?>
        <a href="#" onclick="return $.remove(this)" title="Remove" class="remove">Remove</a>
        <a href="#" onclick="return $.duplicate(this)" title="Add" class="add">Add</a>
    </div>
</div>
<?php endforeach;?>
<?php endif;?>
</div>